Execution of a communication protocol in a communication device may be controlled by a computer program carried out by at least one processor of the communication device. The execution of the communication protocol comprises reception of inputs from a counterpart device communicating with the communication device according to the communication protocol. The inputs may comprise authentication data, configuration data, other protocol control data, or application payload data transferred over the communication protocol. The communication device processes the inputs and provides a response to the input according to a program code of the computer program. The response to the inputs should comply with the specifications of the communication protocol, security parameters, etc. For example, reception of false authentication data as the input should not result in successful authentication.